import Im from "../components/Im";
import Notice from "../components/Notice";
import "./index.less";

function ChatContent(props: any) {
  const { content } = props;
  return (
    <>
      <div className="chat-content">
        <div className="title-content chat-content-title">
          <p>{content.type === "notice" ? "消息" : ""}</p>
        </div>
        {content.type === "im" && <Im content={content}/>}
        {content.type === "notice" && <Notice/>}
      </div>
    </>
  );
}

export default ChatContent;
